

class Numbered(object):
    
    def __init__(self, sequence):
        self.sequence = sequence
        
    def __iter__(self):
        i = 0
        for x in self.sequence:
            yield (i, x)
            i += 1
